import request from '~/utils/resquest'

// 查询回路配置颜色数据
export const getLoopConfigureColors = () =>
  request({
    url: '/api/gxsaas-assets/gisApi/getLoopColors',
    method: 'get'
  })

// 根据条件查询配电箱回路
export const getLoopMonitoringBoxList = <T>(params: T) =>
  request({
    url: '/api/gxsaas-assets/distributionloop/selectBoxList',
    method: 'get',
    params
  })

// 根据条件查询配电箱回路（配电设施里的）
export const getPowerDistributionFacilityCircuit = <T>(params: T) =>
  request({
    url: '/api/gxsaas-assets/distributionloop/getDistributionLoopByMainId',
    method: 'get',
    params
  })

// 根据回路id查询配电id
export const getDistributionIdByLoopId = <T>(params: T) =>
  request({
    url: '/api/gxsaas-assets/distributionloop/getDistributionIdByLoopId',
    method: 'get',
    params
  })

// 检查配电设施的回路版本
export const getDistributionCheckLoopVersion = <T>(params: T) =>
  request({
    url: '/api/gxsaas-assets/distribution/checkLoopVersion',
    method: 'get',
    params
  })
